<template>
  <div class="fontSizeStyle" v-show="showBackGround">
    <span>背景色</span>
    <el-color-picker v-model="color1" @change="handleChange"></el-color-picker>
  </div>
</template>

<script>
export default {
  data() {
    return {
      showBackGround: false,
      color1: "rgb(233, 214, 192)",
    };
  },

  components: {},

  computed: {},

  mounted() {},

  methods: {
    open() {
      this.showBackGround = !this.showBackGround;
    },
    close() {
      this.showBackGround = false;
    },
    handleChange(val) {
      console.log(val);
      this.$emit("changeBackGround", val);
    },
  },
};
</script>
<style lang='scss' scoped>
.fontSizeStyle {
  width: 20rem;
  height: 5rem;
  border-radius: 10px;
  position: absolute;
  top: 34.5%;
  left: 100%;
  background: rgba(245, 245, 245, 0.9);
  display: flex;
  align-items: center;
  justify-content: space-around;
}
</style>